import React from 'react';
import PropTypes from 'prop-types';
import { useNavigate } from 'react-router-dom';
import styles from './index.module.less'; // 导入CSS模块

function MoreBtn(props) {
    const navigate = useNavigate();
    const moreClick = () => {
        navigate(props.url);
    };
    return (
        <button className={styles.findMore} onClick={moreClick}>{`了解更多>`}</button>
    );
}

MoreBtn.propTypes = {
    url: PropTypes.string.isRequired
};

export default MoreBtn;
